package com.xc.disk.config;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;


/**
 * <p>项目名称: Stars</p>
 * <p>描述: 项目配置类</p>
 * <P>创建人: 小程</p>
 * <P>创建人邮箱: 779943476@qq.com</p>
 * <p>创建时间: 2019/7/2</p>
 *
 * @version v1.0
 */
@Data
@Component
@ConfigurationProperties(prefix = "xc.disk")
public class Constants {

    /**
     * 本程序的程序id
     */
    private String appId;

    /**
     * 本程序的秘钥
     */
    private String appSecret;
    /**
     * appId前缀
     */
    private String prefix = "xc";

    /**
     * 登录失败几次启用验证码
     */
    private int openVerifyCodeNum = 5;

    /**
     * 密码错误次数，达到该次数锁定
     */
    private int passwordErrorsNum = 10;

    /**
     * token有效期
     */
    private long expiryTime = 1800000;
    /**
     * 邮件用户名
     */
    private String mailAccount = "";

    /**
     * 邮件密码
     */
    private String authorizationCode = "";

    /**
     * 签名过期时间
     */
    private Long signExpiryTime = 1800000L;

    /**
     * 存放有效文件服务
     */
    private String fileServerKey = "fileServer";
    /**
     * 上传的url
     */
    private String uploadUrl = "/file/upload";
    /**
     * 下载的url
     */
    private String downloadUrl = "/file/download/";
    /**
     * 删除文件url
     */
    private String deleteFileUrl = "/file/delete/";

    /**
     * 检测状态
     */
    private String checkState = "/check/state";

    /**
     * 下载文件key前缀
     */
    private String downloadKey = "download_";

    /**
     * 系统名称
     */
    private String systemName = "xc";
    /**
     * 开发文件目录
     */
    private String devFolder = "dev";
    /**
     * 共享文件url
     */
    private String sharePageUrl = "";
}
